
class Person{
	constructor() { 
		this.name = '米库科技'
		this.sex = 'boy'
	}
	get name(){
		//console.log(`获取名称:${this.name}`)
		return this._name
	}
	set name(val){
		//console.log(`设置名称输出测试:${val}`)
		this._name = val
		return this
	}
	get sex(){
		return this.sex
	}
	set sex(val){
		this._sex = val
		return this
	}
	say(){
		console.log('father say hello')
	}
}
class Boy extends Person{
	//构造函数
	sonstructor(){
		
	}
	say(){
		super.say() 
		console.log('son say goodmorning')
	}
	
}
let son = new Boy()
son.name = 'Chunhui'
console.log(son.name)
son.say()
